package com.qf;

import com.alibaba.druid.pool.DruidDataSource;
import org.apache.ibatis.datasource.pooled.PooledDataSource;
import org.apache.ibatis.datasource.pooled.PooledDataSourceFactory;

import javax.sql.DataSource;

/**
 * @author langazhe
 * @version V1.0
 * @Project mavens
 * @Package com.qf
 * @Description:
 * @Date 2022/5/18 20:32
 */
public class MyDataSource extends PooledDataSourceFactory {
    /**
     * 返回我们期望返回的连接池
     * @return
     */
//    @Override
//    public DataSource getDataSource () {
//        //返回durid的连接池
//        return new DruidDataSource();
//    }

    //重写构造方法
    public MyDataSource () {
        this.dataSource=new DruidDataSource();
    }
}
